/*
 * TITLE:ResponseBoardAnswer
 * AUTHOR:Manori Thakur
 * PURPOSE: Processes the response to indicate player whether the answer is correct
 */
package clientresponse;

import android.util.Log;
import clientcore.Question;
import java.io.IOException;

public class ResponseBoardAnswer extends ResponseFromServer {
	private static final String TAG = ResponseBoardAnswer.class.getSimpleName();
    private short option;
    private int char_id,length;
    private String name;
    private boolean status;
    public static Question question;

    @Override
    public short process() {
    	// Protocol: (int) id, (String) name, (short) option, (boolean) status
        char_id = super.readInt(inFromServer);
        name = super.readString(inFromServer);
        option = super.readShort(inFromServer);
        status = super.readBoolean(inFromServer);
        ResponseBoardQuestion.question.setChoice(option);
        ResponseBoardQuestion.question.setStatus(status);
        return -2;
    }

}
